#include "Thread.h"
#include <stdio.h>


class testThread:public Thread{
	public:
		unsigned int a, b;
		testThread(unsigned int stack_size = 0):Thread(stack_size){}
		void nur(int a){
		
		}
		void pur(){
		
		}
		void run(){
			nur(0x25252525);
		}
};


int main(){
	testThread *t_thrd = new testThread();
	unsigned int * startobj = (unsigned int *)t_thrd;
	printf("sizeof testThread = %i\n", sizeof(testThread));
	printf("t_thrd[0] = %X\n", startobj[0]);
	printf("t_thrd[1] = %X\n", startobj[1]);
	printf("t_thrd[2] = %X\n", startobj[2]);
	printf("t_thrd[3] = %X\n", startobj[3]);
	printf("t_thrd[4] = %X\n", startobj[4]);
	printf("t_thrd[5] = %X\n", startobj[5]);
	
	t_thrd->a = 0x22222222;
	t_thrd->b = 0x33333333;
	t_thrd->setTid(0x77777777);
	t_thrd->setStackSize(0x88888888);
	printf("\n\nt_thrd[0] = %X\n", startobj[0]);
	printf("t_thrd[1] = %X\n", startobj[1]);
	printf("t_thrd[2] = %X\n", startobj[2]);
	printf("t_thrd[3] = %X\n", startobj[3]);
	printf("t_thrd[4] = %X\n", startobj[4]);
	printf("t_thrd[5] = %X\n", startobj[5]);
	
	t_thrd->start();
	t_thrd->stop();
	
	return 0;
}

